function n(n) {
    return t || (t = new Promise(function(n) {
        wx.request({
            url: "https://oss.ibos.cn/common/json/site/icon.json",
            success: function(t) {
                var e = t.data;
                return n(e);
            }
        });
    })), t.then(function(t) {
        return "nav" === n ? t.map(function(n) {
            return Object.assign({}, n, {
                list: n.list.filter(function(n) {
                    return !n.tabOnly;
                })
            });
        }) : t;
    });
}

Object.defineProperty(exports, "__esModule", {
    value: !0
}), exports.default = n, exports.getIconById = function() {
    var t = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : 1;
    return n().then(function(n) {
        return new Promise(function(e) {
            n.forEach(function(n) {
                n.list.forEach(function(o) {
                    o.id === t && e({
                        type: n.type,
                        icon: o
                    });
                });
            });
        });
    });
};

var t = void 0;